<html>
<head><meta charset="utf-8"><title>New perf optimization workflow · t-compiler/rust-analyzer · Zulip Chat Archive</title></head>
<h2>Stream: <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/index.html">t-compiler/rust-analyzer</a></h2>
<h3>Topic: <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/topic/New.20perf.20optimization.20workflow.html">New perf optimization workflow</a></h3>

<hr>

<base href="https://rust-lang.zulipchat.com">

<head><link href="https://rust-lang.github.io/zulip_archive/style.css" rel="stylesheet"></head>

<a name="232399800"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/185405-t-compiler/rust-analyzer/topic/New%20perf%20optimization%20workflow/near/232399800" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> matklad <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/topic/New.20perf.20optimization.20workflow.html#232399800">(Mar 30 2021 at 09:52)</a>:</h4>
<p>PSA: I've pushed <a href="https://github.com/rust-analyzer/rust-analyzer/pull/8254">https://github.com/rust-analyzer/rust-analyzer/pull/8254</a> to optimize debugging perf issues. The idea is that you write a <code>#[test]</code> that reproduces the perf problem exactly, with Cargo.toml and such, and then you have a fast iteration when applying changes.</p>



<a name="232399879"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/185405-t-compiler/rust-analyzer/topic/New%20perf%20optimization%20workflow/near/232399879" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> matklad <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/topic/New.20perf.20optimization.20workflow.html#232399879">(Mar 30 2021 at 09:53)</a>:</h4>
<p>I am somewhat emberrassed that it took me years to add that -- so far, I've been debugging perf by running <code>cargo xtask install &amp;&amp; code .</code>, which isn't very productive.</p>



<a name="232402052"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/185405-t-compiler/rust-analyzer/topic/New%20perf%20optimization%20workflow/near/232402052" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Kirill Bulatov <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/topic/New.20perf.20optimization.20workflow.html#232402052">(Mar 30 2021 at 10:12)</a>:</h4>
<p>So, now instead of generating the pseudoproject for the completions benchmark, we can pick some nasty real crate?</p>



<a name="232404640"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/185405-t-compiler/rust-analyzer/topic/New%20perf%20optimization%20workflow/near/232404640" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> matklad <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/topic/New.20perf.20optimization.20workflow.html#232404640">(Mar 30 2021 at 10:37)</a>:</h4>
<p>I guess that's more for debugging specific issues rather than for benchmarkin</p>



<a name="232404685"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/185405-t-compiler/rust-analyzer/topic/New%20perf%20optimization%20workflow/near/232404685" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> matklad <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/topic/New.20perf.20optimization.20workflow.html#232404685">(Mar 30 2021 at 10:37)</a>:</h4>
<p>it's a replacement for <code>analysis stats</code>, which works for more fine-grained operations</p>



<a name="232409902"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/185405-t-compiler/rust-analyzer/topic/New%20perf%20optimization%20workflow/near/232409902" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Laurențiu <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/topic/New.20perf.20optimization.20workflow.html#232409902">(Mar 30 2021 at 11:29)</a>:</h4>
<p><code>analysis-bench</code>?</p>



<a name="232410690"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/185405-t-compiler/rust-analyzer/topic/New%20perf%20optimization%20workflow/near/232410690" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> matklad <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/topic/New.20perf.20optimization.20workflow.html#232410690">(Mar 30 2021 at 11:37)</a>:</h4>
<p>Kind-of -- I think no one actually used analysis-bench</p>



<a name="232412641"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/185405-t-compiler/rust-analyzer/topic/New%20perf%20optimization%20workflow/near/232412641" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Laurențiu <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/topic/New.20perf.20optimization.20workflow.html#232412641">(Mar 30 2021 at 11:57)</a>:</h4>
<p>I actually used it a couple of times in <a href="https://github.com/rust-analyzer/rust-analyzer/issues/5397">https://github.com/rust-analyzer/rust-analyzer/issues/5397</a></p>



<hr><p>Last updated: Aug 07 2021 at 22:04 UTC</p>
</html>